<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <title>Statistieken enquete</title>
    </head>
    <body>
        <jsp:include page="include/header.jsp"/>
        <div id="content">
            <h2>${titel}</h2>
            Statistieken: 
            <table border="1">
                <tr>
                    <th>Vraag</th>
                    <th>Antwoord</th>
                    <th>Percentage beantwoording</th>
                </tr>
                <c:forEach items="${result}" var="vraagList">
                    <c:forEach items="${vraagList}" var="vraagMap">
                        <tr>
                            <td>${vraagMap['vraagstelling']}</td>
                            <td>${vraagMap['antwoord']}</td>
                            <td>${vraagMap['percentage']}</td>
                        </tr>
                    </c:forEach>
                </c:forEach>
            </table>
        </div>
    </body>
</html>